package com.fcat.common.user.vo;

import lombok.Data;

@Data
public class ResourceInfo implements Comparable<ResourceInfo>{
    String resourceId;
    String type;
    String name;
    String displayName;
    String uri;
    String iconUri;
    /*
    是否已经添加导航/桌面的状态true/false
     */
    boolean enble;
    /*
    父级菜单，即二级菜单，如果为空表示没有，如果不为空则需要把原先是二级的变成三级
     */
    String parentMenus;
    String id;
    String parentId;
    Integer index;

    Integer firstSort;
    Integer secondSort;
    Integer thirdSort;
    public static Integer Level=1;


    @Override
    public int compareTo(ResourceInfo resourceInfo) {
            if(resourceInfo.getIndex()==null || this.getIndex()==null){
                return 0;
            }
            return this.getIndex().compareTo(resourceInfo.getIndex());

    }

//    public ResourceInfo(Integer firstSort,String type) {
//        this.type = type;
//        this.firstSort = firstSort;
//    }
}
